package com.ibeeking.gmc.global.g.rest.controller.v1;

import com.ibeeking.gmc.global.api.common.dto.TenantUserDTO;
import com.ibeeking.nematos.constants.enums.OperateLogTypeEnum;
import com.ibeeking.nematos.log.annotation.Log;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

/**
 * @ClassName TenantController
 * @Description
 * @Author ibeeking
 * @Date 2020-12-24 09:21
 **/
@RestController
@RequestMapping("/g/tenantUser/v1")
public class TenantUserController {

    @Resource
    private com.ibeeking.gmc.global.g.rest.service.ITenantUserService ITenantUserService;

    @Log(logType = OperateLogTypeEnum.QUERY, describe = "租户用户列表查询")
    @PostMapping(value = "/effectiveList/{tenantId}")
    public List<TenantUserDTO> pageList(@PathVariable("tenantId") String tenantId) {
        return ITenantUserService.queryEffectUserByTenantId(tenantId);
    }

}
